package Java.Class;

import java.util.HashMap;
import java.util.Scanner;

//hashmap集合的应用
public class Coid {
    private HashMap<Integer, String> hashMap = new HashMap<Integer, String>();

    public Coid() {
        hashMap.put(1, "penny");
        hashMap.put(10, "dime");
        hashMap.put(25, "quarter");
        hashMap.put(50, "half-dolar");
        System.out.println(hashMap.keySet());
        System.out.println(hashMap);
        for (Integer k : hashMap.keySet()) {
            String s = hashMap.get(k);
            System.out.println(s);
        }
    }

    public String getValue(int amount) {
        if (hashMap.containsKey(amount)) {
            return hashMap.get(amount);
        } else {
            return "not found";
        }
    }

    public static void main(String[] args) {

        Scanner in = new Scanner(System.in);
        int amount = in.nextInt();
        Coid coid = new Coid();
        String s = coid.getValue(amount);
//        System.out.println(s);
    }
}
